package app

import cc.vv.BaseNewApplication
import cc.vv.baselibrary.util.LK
import cc.vv.lkimagecomponent2.LKImage
import cc.vv.lkimagecomponent2.lib.mode.DiskCacheMode
import com.tencent.mm.opensdk.openapi.IWXAPI
import com.tencent.mm.opensdk.openapi.WXAPIFactory

class AppApplication : BaseNewApplication() {

    companion object {
        var msgApi: IWXAPI? = null
    }

    override fun onCreate() {
        super.onCreate()
        LK.Ext.init(this)

        msgApi = WXAPIFactory.createWXAPI(applicationContext, null)
        msgApi?.registerApp("wx5b6536575f22fe33")

        //初始化图片加载框架
        LKImage.init(applicationContext, "LKIMAGE_TAG").gifRepeatCount(-1)
                .cacheMaxSize(400).cacheFileName("imageCache").diskCacheStrategy(DiskCacheMode.AUTOMATIC)
                .over()
    }

}